{
 "cells": [
  {
   "cell_type": "code",
   "execution_count": 1,
   "id": "50d00813-99c2-4c11-adec-87e3fcd4ce80",
   "metadata": {},
   "outputs": [],
   "source": [
    "import torch\n",
    "from torch.utils.data import TensorDataset\n",
    "import numpy as np"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 2,
   "id": "4f8278bc-d0ac-405d-951e-3bf1b26e6680",
   "metadata": {},
   "outputs": [],
   "source": [
    "X = torch.randn([8, 4])\n",
    "Y = torch.randn([8, 1])\n",
    "\n",
    "dset = TensorDataset(X, Y)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 3,
   "id": "b6dfa45d-2f46-4fe8-831c-3aaf494a8229",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "tensor([[-2.2444,  2.1772, -0.6129, -0.8201],\n",
       "        [-0.7740,  0.3722, -0.6326, -0.0845],\n",
       "        [-1.4645,  0.2466, -0.2805, -1.3529],\n",
       "        [-0.8508, -0.8165,  0.1587,  0.6912],\n",
       "        [-1.3859, -0.3966, -0.7486, -0.1102],\n",
       "        [ 0.9365,  2.2750, -0.9664, -0.2576],\n",
       "        [ 0.3291, -0.9053,  0.2634,  0.8090],\n",
       "        [ 0.6502, -1.3632,  0.0203, -0.1983]])"
      ]
     },
     "execution_count": 3,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "dset[:][0]"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 5,
   "id": "2d658dbb-c5a4-472b-94c0-87b3206e1b61",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "2.0"
      ]
     },
     "execution_count": 5,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "np.power(8, 1/3)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 8,
   "id": "34ab591e-3bff-490f-989f-05da4352c0ce",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "0.18333196073798502"
      ]
     },
     "execution_count": 8,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "np.sqrt(0.1288) * 0.3904 + (0.3367-0.1288)**2"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "id": "c4d062e1-ac01-4206-a696-a55998fa9086",
   "metadata": {},
   "outputs": [],
   "source": []
  }
 ],
 "metadata": {
  "kernelspec": {
   "display_name": "Python 3 (ipykernel)",
   "language": "python",
   "name": "python3"
  },
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 3
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython3",
   "version": "3.9.7"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 5
}
